package datastructures;

/**
 * Tabulka lokalnich promennych
 * @author honzee
 */
public class LocalsTable {

    private final Integer table[];

    public LocalsTable(Integer tableSize) {
        this.table = new Integer[tableSize];
    }

    public void put(Integer slot, Integer value) {
        table[slot] = value;
    }

    /**
     * Vraci hodnotu ze zadaneho slotu tabulky
     */
    public Integer get(Integer slot) {
        return Integer.valueOf(table[slot]);
    }
}
